

#ifndef UC_GECYLNDR_H
#define UC_GECYLNDR_H

#include "zgegbl.h"
#include "zgesurf.h"
#include "zgevec3d.h"
#include "zgeintrvl.h"
#include "zgearc3d.h"
#pragma pack (push, 8)

class UcGeCircArc3d;

class
GX_DLLEXPIMPORT
UcGeCylinder : public UcGeSurface
{
public:
    UcGeCylinder ();
    UcGeCylinder (double radius, const UcGePoint3d& origin,
                  const UcGeVector3d& axisOfSymmetry);
    UcGeCylinder (double radius, const UcGePoint3d& origin,
                  const UcGeVector3d& axisOfSymmetry,
                  const UcGeVector3d& refAxis,
                  const UcGeInterval& height,
                  double startAngle, double endAngle);
    UcGeCylinder (const UcGeCylinder&);

    double         radius        () const;
    UcGePoint3d    origin        () const;
    void           getAngles     (double& start, double& end) const;
    void           getHeight     (UcGeInterval& height) const;
    double         heightAt      (double u) const;
    UcGeVector3d   axisOfSymmetry() const;
    UcGeVector3d   refAxis       () const;
    ZSoft::Boolean isOuterNormal () const;
    ZSoft::Boolean isClosed      (const UcGeTol& tol = UcGeContext::gTol) const;

    UcGeCylinder&  setRadius     (double radius);
    UcGeCylinder&  setAngles     (double start, double end);
    UcGeCylinder&  setHeight     (const UcGeInterval& height);
    UcGeCylinder&  set           (double radius, const UcGePoint3d& origin,
                                  const UcGeVector3d& axisOfSym);
    UcGeCylinder&  set           (double radius, const UcGePoint3d& origin,
                                  const UcGeVector3d& axisOfSym,
                                  const UcGeVector3d& refAxis,
                                  const UcGeInterval& height,
                                  double startAngle, double endAngle);

    UcGeCylinder&  operator =    (const UcGeCylinder& cylinder);

    ZSoft::Boolean intersectWith (const UcGeLinearEnt3d& linEnt, int& intn,
                                  UcGePoint3d& p1, UcGePoint3d& p2,
                                  const UcGeTol& tol = UcGeContext::gTol) const;
};

#pragma pack (pop)
#endif
